from django.urls import path, include
from article import views

urlpatterns = [
    path('users/', views.UserList.as_view()),  # 用户列表
    path('login/', views.Login.as_view()),  # 登录
    path('loginout/', views.LoginOut.as_view()),  # 登出
    path('list/', views.ArticleList.as_view()),  # 文章列表，查所有
    path('detail/<int:pk>/', views.ArticleDetail.as_view()),  # 文章增删改查单个
    path('like/', views.LikeList.as_view()),  # 点赞列表
    path('<int:pk>/like/', views.LikeArticle.as_view()),  # 点赞
    path('book/', views.Book.as_view()),
]
